{include file="public/header" /}
<body>
<div class="x-body">
    <form action="{:url('save')}" class="layui-form" id="form">
        {foreach name="field" item="form"}
            {switch form.format}

            {case value="input"}
            {include file="form/items/input" type='' /}
            {/case}

            {case value="number"}
            {include file="form/items/number" type='' /}
            {/case}

            {case value="ratio"}
            {include file="form/items/ratio" type='' /}
            {/case}

            {case value="select"}
            {include file="form/items/select" type='' /}
            {/case}

            {case value="img"}
            {include file="form/items/img" type='' /}
            {/case}

            {case value="rich_text"}
            {include file="form/items/rich_text" type='' /}
            {/case}

            {case value="password"}
            {include file="form/items/password" type='' /}
            {/case}

            {default /}

            {/switch}
        {/foreach}
        <div class="layui-form-item layui-layout-admin">
            <div class="layui-input-block">
                <div class="layui-footer" style="left: 0;">
                    <button class="layui-btn" lay-filter="save" lay-submit formObj="#form">保存</button>
                </div>
            </div>
        </div>
    </form>
</div>
</body>
{include file="public/footer" /}
</html>